<extend name="Base/common"/>

<block name="style">
    <link href="__CSS__/shops.css" rel="stylesheet" type="text/css"/>
</block>
<block name="header">
<include file="_nav"/>
</block>
<block name="body">

<div class="container">
<div class="row shop">
    <div class="col-xs-12   clearfix">
        <div class="col-xs-12 common_block_border pad_15">
           

          <div class="container">
        <div class="clearfix">

            <div class="clearfix">
                <div class="col-xs-9">
                    <div class="common-block">
                        <div class="col-xs-3 text-center">
                            <img class="appstore_cover-detail" src="http://upload.opensns.cn/Uploads_Picture_2015-09-21_55ffc5385762c.jpg?imageView2/1/w/160/h/160">                        </div>
                        <div class="col-xs-9">
                            <article class="article">
                                <header>
                                    <h1 class="text-center">Api —— 1.4.0                                        
                                        <div class="pull-right">
                                            <a data-role="watch" class="share-btn" data-toggle="tooltip" data-title="提示消息提示消息" title="">
                                              <i class="icon-unlink"></i>
                                              <span data-role="words">订阅</span><span data-role="num">44</span>
                                            </a>
                                        </div>
                                    </h1>
                                    <dl class="dl-inline">
                                        <dt>上架时间：</dt>
                                        <dd>2015-12-15</dd>
                                        <dt></dt>
                                        <dd class="pull-right"><span class="label label-success">版本：1.4.0</span>
                                            <span class="label label-danger"> 下载次数： 511</span>
                                            <span class="label label-danger"> 销量： 61</span>
                                        </dd>
                                    </dl>

                                    <dl class="dl-inline" style="position: relative">
                                        <dt>开发者：</dt>
                                        <dd>官方</dd>
                                        <dt>
                                            上传者
                                        </dt>
                                        <dd>
                                            <a href="#">admin</a>
                                        </dd>
                                    </dl>
                                </header>
                                <div class="pull-right">
                                  <p>售价：<span class="price">&yen;2000</span></p>
                                  <button class="btn-block btn btn-danger">立即购买</button>
                                </div>
                                
                            </article>
                        </div>
                
                      <article class="clearfix">
   

    <section>
        <ul id="myTab" class="nav nav-tabs">
            <li class="active">
                <a href="#tab1" data-toggle="tab">商品详情</a>
            </li>
            <li class="dropdown">
                <a href="#history" data-toggle="tab">更新历史</a>
            </li>
        </ul>

        <div class="tab-content" style="border: 1px solid #ddd;border-top: none;padding: 5px;margin-bottom: 10px;min-height: 400px">
            <div class="tab-pane active" id="tab1">
                <div class="pad_15">
                  商品详情
                </div>
            </div>
            <div class="tab-pane" id="history">
              <div class="pad_15">
                  更新历史。。。
              </div>
            </div>
        </div>

    </section>

</article>
<section style="padding: 0 20px 20px;">  
<style>
    #consult ul {
        margin-bottom: 0px;
        list-style: none;
    }

    #consult li {
        float: left;
        padding: 5px 10px;
    }

    #consult li.current {
        padding: 11px 10px 6px;
        margin: -6px 0 -1px -1px;
        background: white;
        border-left: 1px solid #DFDFDF;
        border-right: 1px solid #DFDFDF;
        border-top: 2px solid #4F8AD0;
    }
    #consult li.current a{
        text-decoration: none;
    }
    #consult-list .item{
        padding: 8px 0;
        border-bottom: 1px dotted #DEDEDE;
    }
    #consult-list .item .user{
        margin-top: 0;
        color: #9C9A9C;
    }
    #consult-list .item .user span{
        margin-right: 10px;
    }
    #consult-list .item dl{
        margin-bottom: 5px;
        margin-top: 5px;
    }
    #consult-list .item dt{
        float: left;
        width: 65px;
    }
    #consult-list .item dd{
        margin-left: 65px;
    }
</style>
</section>
</div>
</div>


<div class="col-xs-3 ">
    <div class="common-block">
        <header>服务商</header>
        <section>
            <div class="clearfix">
                <div class="col-xs-4">
                    <div class="row"><a href="#"><img src="http://upload.opensns.cn/Uploads_Picture_2015-11-30_565becca9d65c.png?imageView2/1/w/75/h/75"></a>
                    </div>
                </div>
                <div class="col-xs-8 ">
                    <div class="text-ellipsis">
                        <a style="color:red" href="#">OS官方旗舰店</a>
                        <img title="官方认证店" alt="官方认证店" src="/Application/Appstore/Static/images/icon-official.png">
                      </div>
                    <div class="text-ellipsis">店主：<a target="_blank" href="#">admin</a></div>
                </div>
            </div>

            <p></p>

            <a href="tencent://message/?uin=3288307190&amp;Menu=yes" class="btn btn-success btn-xs"> 立即咨询</a> &nbsp;&nbsp;
            <!-- <a href="#" class="btn btn-success btn-xs"><i class="icon-inbox"></i>
                进入店铺</a> -->
        </section>

        <hr class="margin-0">

        <header>作者的其他作品</header>

        <section>
            <div class="row side_plug_in">
                <div class="col-md-6">
                    <a href="/appstore/plugindetail_236.html"><img class="appstore_cover" src="http://upload.opensns.cn/Uploads_Picture_2015-08-13_55cc46744665d.png?imageView2/1/w/90/h/90"></a>
                </div>

                <div class="col-md-6 col_left text-ellipsis">
                    <p class="tem_name_item text-more">
                      <a href="/appstore/plugindetail_236.html">空间换肤插件</a>
                    </p>
                    <p><span class="count">246</span> 次下载</p>
                    <p><span><a title="">人民币&nbsp;1&nbsp;元</a></span></p>
                </div>
            </div> 
        </section>
        <hr style="margin-top: 5px;margin-bottom: 5px;">

        <header>本类最近更新</header>

        <section>
            <div class="row side_plug_in">
                <div class="col-md-6">
                    <a href="/appstore/plugindetail_240.html"><img class="appstore_cover" src="http://upload.opensns.cn/Uploads_Picture_2015-09-21_55ffc5385762c.jpg?imageView2/1/w/90/h/90"></a>
                </div>

                <div class="col-md-6 col_left text-ellipsis">
                    <p class="tem_name_item text-more">
                      <a href="/appstore/plugindetail_240.html">RestfulApi</a>
                    </p>
                    <p><span class="count">511</span> 次下载</p>
                    <p><span><a title="">人民币&nbsp;20000&nbsp;元</a></span></p>
                </div>
            </div>
        </section>

    </div>
</div>

</div>
</div>
</div>
</div>
<div class="col-xs-12  pad_15">

</div>
</div>
<if condition="is_login()">
    <!-- Modal -->
    <div id="frm-post-popup" class="white-popup mfp-hide" style="max-width: 500px;">
        <h2>收货信息填写<span style="font-size: 12px;color: #BEBEBE;">(为了确保您能收到商品，请正确填写收货信息)</span></h2>

        <div class="aline" style="margin-bottom: 10px"></div>
        <div class="row">
            <form class="form-horizontal  ajax-form" role="form" action="{:U('Shop/Index/goodsBuy')}" method="post">
                <input type="hidden" id="goods_id" name="id" value="">
                <input type="hidden" name="address_id" value="{$shop_address['id']}">

                <div class="form-group">
                    <label for="name" class="col-xs-2 control-label" style="width: 20%">姓名</label>

                    <div class="col-xs-10" style="width: 60%">
                        <input id="name" name="name" type="text" class="form-control"
                               value="{$shop_address['name']}" placeholder="姓名"/>
                    </div>
                </div>
                <div class="form-group">
                    <label for="address" class="col-xs-2 control-label" style="width: 20%">收货地址</label>

                    <div class="col-xs-10" style="width: 60%">
                        <textarea id="address" name="address" class="form-control" placeholder="收货地址"
                                  style="max-width: 310px">{$shop_address['address']}</textarea>
                    </div>
                </div>
                <div class="form-group">
                    <label for="zipcode" class="col-xs-2 control-label" style="width: 20%">邮编</label>

                    <div class="col-xs-10" style="width: 60%">
                        <input id="zipcode" name="zipcode" type="text" class="form-control"
                               value="{$shop_address['zipcode']}" placeholder="邮编"/>
                    </div>
                </div>
                <div class="form-group">
                    <label for="phone" class="col-xs-2 control-label" style="width: 20%">手机号码</label>

                    <div class="col-xs-10" style="width: 60%">
                        <input id="phone" name="phone" type="text" class="form-control"
                               value="{$shop_address['phone']}" placeholder="手机号码"/>
                    </div>
                </div>
                <div class="form-group">
                    <div class="col-sm-offset-2 col-xs-10">
                        <button type="submit" class="btn btn-primary ">提交</button>
                    </div>
                </div>
            </form>
        </div>


    </div>
    <!-- /.modal -->
</if>
</div>
<input type="hidden" id="money_name" value="{$money_type.title}"/>
</block>

<block name="script">
    <script type="text/javascript" src="__STATIC__/uploadify/jquery.uploadify.min.js"></script>
    <script>
        var money_name = $('#money_name').val().trim();
        $(function () {
            $('.exchange_goods').click(function () {
                if (MID == 0) {
                    toast.info('登录后才能兑换商品！', '提示消息');
                    return false;
                }
                var goods_id = this.getAttribute('goods_id');
                $('#goods_id').val(goods_id);
            });
            if (MID != 0) {
                $('.money_not_enough').click(function () {
                    toast.info('你的' + money_name + '不足！', '提示消息');
                    return false;
                });
                $('.open-popup-link').magnificPopup({
                    type: 'inline',
                    midClick: true, // Allow opening popup on middle mouse click. Always set it to true if you don't provide alternative source in href.
                    closeOnBgClick: false
                });
            }
            $('.item_goods').mouseover(function () {
                $(this).addClass('item_goods_box_shadow');
            });
            $('.item_goods').mouseleave(function () {
                $(this).removeClass('item_goods_box_shadow');
            });

            $('#myTab a').click(function (e) {
              e.preventDefault();
              $(this).tab('show');
            })
            $('[data-role="watch"]').tooltip('toggle');

        })
    </script>
</block>
